package com.leeon.generics;

class D{
	public <T extends AInterface> void g(T t){
		t.A();
		t.B();
	}
}

public class AImpl implements AInterface{

	@Override
	public void A() {
		System.out.println("a()");
	}

	@Override
	public void B() {
		System.out.println("b()");
		
	}
	
	public void C(){
		
	}
	
	public static void main(String[] args){
		D d = new D();
		d.g(new AImpl());
	}

}
